<?php
/**
 * Created by PhpStorm.
 * User: micoya
 * Date: 2018/11/6
 * Time: 11:24 AM
 */

namespace app\common\base;


use think\Validate;

class Form {

    // 验证表单数据
    public static function Validate($rule) {
        $validator = new Validate();
        $validator = $validator->rule($rule);
        if (!$validator->check(input())) {
            DieParamsError();
        }
    }

}
